package A01File;

import java.io.File;

public class FileDemo2 {
    public static void main(String[] args) {
        File file1 = new File("D:\\File\\a.txt");
        System.out.println(file1.isFile());
        System.out.println(file1.isDirectory());
        System.out.println(file1.exists());
        System.out.println("------------------");
        File file2 = new File("D:\\File\\bb");
        System.out.println(file2.isFile());
        System.out.println(file2.isDirectory());
        System.out.println(file2.exists());
    }
}
